<?php

use Illuminate\Http\Request;

/*
|--------------------------------------------------------------------------
| API Routes
|--------------------------------------------------------------------------
|
| Here is where you can register API routes for your application. These
| routes are loaded by the RouteServiceProvider within a group which
| is assigned the "api" middleware group. Enjoy building your API!
|
*/

Route::get('/user', function (Request $request) {
    return $request->user();
})->middleware('auth:api');

// 私人访问令牌
// 获取
Route::get('/mypassport/personal', 'PassportApiController@passportPersonal');
Route::get('/mypassport/personal/test', 'PassportApiController@passportPersonalTest')->middleware('auth:api');

// 密码授权令牌
Route::get('/mypassport/password/test', 'PassportApiController@passportPasswordTest')->middleware('auth:api');

// 授权码授权令牌


